<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title></title>
    <script type="text/javascript">
function fadeOut(elem, speed, opacity){
        /*
        * 参数说明
        * elem==>需要淡入的元素
        * speed==>淡入速度,正整数(可选)
        * opacity==>淡入到指定的透明度,0~100(可选)
        */

       speed = speed || 20;
       opacity = opacity || 0;
       //初始化透明度变化值为0
       var val = 100;
        //循环将透明值以5递减,即淡出效果
       (function(){
           iBase.SetOpacity(elem, val);
           val -= 5;
           if (val >= opacity) {
               setTimeout(arguments.callee, speed);
           }else if (val < 0) {
                //元素透明度为0后隐藏元素
               elem.style.display = 'none';
           }
       })();
    }
      </script>
  </head>
  <body>

  </body>
</html>
